﻿<%@ Page Title="Product" Theme="Mobile" Language="C#" MasterPageFile="~/ProductMaster.master" AutoEventWireup="true" CodeBehind="Product.aspx.cs" Inherits="MobileShop.Product" %>

<%@ Register Src="~/Controls/Common/FBLikeButton.ascx" TagName="FBLikeButton" TagPrefix="uc" %>
<%@ Register Src="~/Controls/Common/GoogleButton.ascx" TagName="GoogleButton" TagPrefix="uc" %>

<asp:Content ID="Content1" ContentPlaceHolderID="bodyContent" runat="server">
    <link type="text/css" rel="Stylesheet" href="styles/product.css" />
    <script type="text/javascript">
        function choosePic(a) {
            $('#<%= imgProduct.ClientID %>').attr('src', $(a).find("img").attr('real'));
        }
    </script>
    <div class='productDetail' style='padding-top:10px' >
        <div class='divImageLeft' style='height:300px'>
            <asp:Image ID="imgProduct" runat="server" Height="100px" />
            <br style='clear:both' />
            <div>
                <asp:DataList ID="rptImages" runat="server" RepeatColumns="2" RepeatLayout="Table" >
                    <ItemTemplate>
                        <div class='smallImage' imgid='<%# Eval("ID") %>' >
                            <div style="text-align:left;vertical-align:top;">
                                <a onclick='<%# "choosePic(this); return false;" %>' title='<%# Eval("Description") %>' >
                                    <img id="Img1" style="border:none" runat="server" real='<%# POSSystem.BLL.Utilities.GetConfigAppSetting("ProductImagePath") + "/" + Eval("ThumbUrl").ToString().Replace("~/", "") %>' src='<%# POSSystem.BLL.Utilities.GetConfigAppSetting("ProductImagePath") + "/" + Eval("ThumbUrl").ToString().Replace("~/", "") %>' alt='<%# Eval("Description") %>' />
                                </a>
                            </div>
                        </div>
                    </ItemTemplate>
                </asp:DataList>
            </div>
        </div>
        <div>
            <asp:Label ID="lblProductName" class='productname' runat="server"></asp:Label><br /><br />
            <asp:Literal ID="litRegularPrice" runat="server"></asp:Literal>
            <b class='productDetailLabel'>Your Price: </b> <asp:Label ID="lblPrice"  class='productprice' runat="server"></asp:Label><br /><br />
            <b  class='productDetailLabel'>Status: </b><asp:Literal ID="litStatus" runat="server"></asp:Literal>

            <br /><br />

            <b  class='productDetailLabel'>Quantity: </b><asp:TextBox ID="txtQuantity"  ValidationGroup="AddCart" runat="server" style='width:30px'>1</asp:TextBox>
            <asp:RequiredFieldValidator ID="reqQuantity" runat="server" ControlToValidate="txtQuantity" ErrorMessage="<span class='required'>required</span>" Text="<span  class='required'>required</span>" ValidationGroup="AddCart" ></asp:RequiredFieldValidator>
            <br /><br />
            <asp:Button ID="btnAddCart" Text="Add Cart" runat="server" OnClick="btnAddCart_OnClick" ValidationGroup="AddCart" />
            <asp:Label ID="lblAddCart" runat="server" Visible="false" class="inputDisabled">Added Cart</asp:Label>
            <asp:Button ID="btnAddWishList" Text="Add Wishlist" runat="server" OnClick="btnAddWishList_OnClick" />
            <asp:Label ID="lblAddWishList" runat="server" Visible="false" class="inputDisabled">Added Wishlist</asp:Label>

            <br /><br />
            <b  class='productDetailLabel'>Quick Overview: </b><asp:Literal ID="litDesc" runat="server"></asp:Literal>
        </div>
        <div style="margin-top:20px; ">
            <uc:FBLikeButton runat="server" ID="ucFBLikeButton" />
            <uc:GoogleButton runat="server" ID="ucGoogleButton" />
        </div>

        <div style="margin-top:10px; clear:both;"></div>
    </div>
</asp:Content>
